package com.rms.service.impl;

import java.util.List;

import com.rms.dao.IFoodTypeDao;
import com.rms.entity.FoodType;
import com.rms.service.IFoodTypeService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;


@Service
public class FoodTypeService implements IFoodTypeService{

	@Resource
	IFoodTypeDao foodTypeDao;
	
	@Override
	public void add(FoodType foodtype) {
		foodTypeDao.add(foodtype);
	}

	@Override
	public void delete(int id) {
		foodTypeDao.delete(id);
	}

	@Override
	public void updata(FoodType foodtype) {
		foodTypeDao.updata(foodtype);
	}

	@Override
	public List<FoodType> query() {
		return foodTypeDao.query();
	}

	@Override
	public FoodType findById(int id) {
		return foodTypeDao.findById(id);
	}

	@Override
	public List<FoodType> query(String keyword) {
		return foodTypeDao.query(keyword);
	}

	@Override
	public Integer getFirstType() {
		return foodTypeDao.getFirstType();
	}
}
